how to derive first equation of motion